#include "RNG.h"

//	random number generator
RNG::RNG(unsigned long long _seed /* = 7564231ULL */)
{
	seed = _seed;
	mult = 62089911ULL;
	llong_max = 4294967295ULL;
	float_max = 4294967295.0f;
}

//	generate random float in [0, 1)
float RNG::operator()()
{
	seed = mult * seed;
	return float(seed % llong_max) / float_max;
}